<%@ page language="java"  pageEncoding="UTF-8"%>

<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>现场办公系统-初始化</title>
<!-- 加载esayUI开始 -->
<script type="text/javascript" src="<%=request.getContextPath()%>/resources/esayUI/1.3.2/jquery.min.js"></script>
<script type="text/javascript" src="<%=request.getContextPath()%>/resources/esayUI/1.3.2/jquery.easyui.min.js"></script>
<link id="easyuiTheme" rel="stylesheet" type="text/css" href="<%=request.getContextPath()%>/resources/esayUI/1.3.2/themes/default/easyui.css"  />
<script type="text/javascript" src="<%=request.getContextPath()%>/resources/esayUI/1.3.2/locale/easyui-lang-zh_CN.js"></script>
<!-- 加载esayUI结束 -->
<script type="text/javascript">
$(function() {
	$.messager.confirm("初始化系统", "此操作将初始化系统数据库，请慎重！", function(r) {
		if (r) {
			var method = <%= request.getAttribute("method")%>;
			$.post("initSYS" , {"method":method}, function(data) {
				if (data && data.result == 1) {
					$.messager.show({title:'成功提示', msg:data.msg, timeout:2000, showType:'slide'});
					setTimeout("window.location.href='<%=request.getContextPath() %>/login'",2000);
				} else {
					$.messager.alert('提示', data.msg, 'warning');
				}
			}, "json");
		};
	});
});
</script>
</head>
<body></body>
</html>